﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<IEnumerable<SistemaBastanteo.Dominio.Cliente>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Index
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">

    <h2>Listado de Clientes </h2>

    <table>
        <tr>
            <th></th>
            <th>
                Codigo
            </th>
            <th>
                Ruc
            </th>
            <th>
                RazonSocial
            </th>
            <th>
                Inicio
            </th>
            <th>
                Empleados
            </th>
        </tr>

    <% foreach (var item in Model) { %>
    
        <tr>
            <td>
                <%: Html.ActionLink("Edit", "Edit", new { Codigo = item.Codigo }) %> |
                <%: Html.ActionLink("Details", "Details", new { Codigo = item.Codigo })%> |
                <%: Html.ActionLink("Delete", "Delete", new { Codigo = item.Codigo })%>
            </td>
            <td>
                <%: item.Codigo %>
            </td>
            <td>
                <%: item.Ruc %>
            </td>
            <td>
                <%: item.RazonSocial %>
            </td>
            <td>
                <%: String.Format("{0:g}", item.Inicio) %>
            </td>
            <td>
                <%: item.Empleados %>
            </td>
        </tr>
    
    <% } %>

    </table>

    <p>
        <%: Html.ActionLink("Nuevo Cliente", "Create")%>
    </p>

</asp:Content>

